export default {
    path: '/product',
    name: 'product',
    redirect: '/product/all',
    component: () => import('@/views/layout/layout.vue'),
    meta: {
        title: '产品管理',
    },
    children: [
        {
            path: 'all',
            name: 'productAll',
            component: () => import('@/views/product/list.vue'),
            meta: {
                title: '所有产品',
                type: '',
            },
        },
        {
            path: 'add',
            name: 'productAdd',
            component: () => import('@/views/product/form.vue'),
            meta: {
                title: '添加产品',
                hidden: true,
            },
        },
        {
            path: 'edit/:id',
            name: 'productEdit',
            component: () => import('@/views/product/form.vue'),
            meta: {
                title: '编辑产品',
                hidden: true,
            },
            props: true,
        },
        {
            path: 'view/:id',
            name: 'productView',
            component: () => import('@/views/product/form.vue'),
            meta: {
                title: '查看产品',
                hidden: true,
            },
            props: true,
        },
        {
            path: 'auth',
            name: 'productAuthList',
            component: () => import('@/views/product/list.vue'),
            meta: {
                title: '待审核',
                type: '0',
            },
        },
        {
            path: 'auth/:id',
            name: 'productAuth',
            component: () => import('@/views/product/list.vue'),
            meta: {
                title: '审核产品',
                hidden: true,
            },
        },
        {
            path: 'draft',
            name: 'productDraft',
            component: () => import('@/views/product/list.vue'),
            meta: {
                title: '草稿箱',
                type: '3',
            },
        },
    ],
};
